read input from dialog box